// Fill out your copyright notice in the Description page of Project Settings.

#pragma once

/**
 * Enum for crossfall side.
 */
enum class FWorldCrossfallSide
{
	Left,
	Right,
	Both
};

inline FWorldCrossfallSide FWorldCrossfallSideFromJson(const json& j)
{
	if (j == "left")	return FWorldCrossfallSide::Left;
	if (j == "right")	return FWorldCrossfallSide::Right;
	if (j == "both")	return FWorldCrossfallSide::Both;
	return FWorldCrossfallSide::Both;
}

inline json FWorldCrossfallSideToJson(FWorldCrossfallSide p)
{
	if (p == FWorldCrossfallSide::Left)		return "left";
	if (p == FWorldCrossfallSide::Right)	return "right";
	if (p == FWorldCrossfallSide::Both)		return "both";
	return "both";
}

inline void from_json(const json& j, FWorldCrossfallSide& p)
{
	p = FWorldCrossfallSideFromJson(j);
}

inline void to_json(json& j, const FWorldCrossfallSide& p)
{
	j = FWorldCrossfallSideToJson(p);
}
